<%-- 
    Document   : delete
    Created on : Mar 4, 2014, 10:36:09 PM
    Author     : Theodoro
--%>

<%@page contentType="text/html" pageEncoding="UTF-8" errorPage="error.jsp"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/sql" prefix="sql"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<c:if test="${sessionScope.username == NULL}">
<c:redirect url="http://webtek.org/Bonix/index.php"/>
</c:if>
<c:set scope="request" var="title" value="Message"/>

<sql:setDataSource user="root" password="" driver="com.mysql.jdbc.Driver"
                   url="jdbc:mysql://localhost/bonix"/>

<sql:update sql = "Delete from messages where entry_id = ?">
    <sql:param value="${fn:trim(param.entry_id)}"/> 

</sql:update>

<!DOCTYPE html>
<html>
    <jsp:include page="head.jsp"/>

    <body>
        <jsp:include page="banner.jsp"/>

        <div class="row">
            <div class="container">
                <div class="content row">

                    <div class="containerService">
                        <div class="panel panel-info">

                            <div class="panel-heading">
                                <h4>Messages</h4>
                                <br>
                                <ul class="list-unstyled list-inline navService navService-pills">
                                    <c:url var="messagesURL" value="messages.jsp">
                                        <c:param name="username" value="${sessionScope.username}"></c:param>
                                    </c:url>
                                    <li><a href="${messagesURL}"> Message Inbox </a></li>
                                        <c:url var="composeURL" value="compose.jsp">
                                            <c:param name="username" value="${sessionScope.username}"></c:param>
                                        </c:url>
                                    <li><a href="${composeURL}"> Compose Message </a></li>
                                        <c:url var="sentItemsURL" value="sentItems.jsp">
                                            <c:param name="username" value="${sessionScope.username}"></c:param>
                                        </c:url>
                                    <li><a href="${sentItemsURL}"> Sent Items </a></li>
                                </ul>
                            </div>

                            <div class="panel-body">
                                <h1>DELETED</h1>
                            </div><!-- END panel-body -->

                        </div><!-- END panel-info -->
                    </div><!-- END containerService -->

                </div><!-- END CONTENT CONTENT ROW -->
            </div><!-- END CONTAINER -->
        </div><!-- END ROW -->

        <jsp:include page="footer.jsp"/>

    </body>
</html>
